﻿<Window x:Class="PeopleViewer.Basic.MainWindow"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        Title="MainWindow" Height="350" Width="525">
    <Border x:Name="LayoutRoot" Padding="5"
            BorderBrush="{StaticResource ApplicationForeground}" BorderThickness="2" 
            Background="{StaticResource ApplicationBackground}">
        <Grid>
            <Grid.ColumnDefinitions>
                <ColumnDefinition Width="*" />
                <ColumnDefinition Width="2*" />
            </Grid.ColumnDefinitions>
            <Grid.RowDefinitions>
                <RowDefinition Height="Auto" />
                <RowDefinition Height="Auto" />
                <RowDefinition Height="Auto" />
                <RowDefinition Height="*" />
                <RowDefinition Height="Auto" />
            </Grid.RowDefinitions>

            <!-- Dynamic Repository Button Panel -->
            <Button x:Name="FetchButton" Grid.Column="0" Grid.Row="0" Margin="5"
                            Content="Dynamic Repository"
                            Click="FetchButton_Click"
                            Style="{StaticResource GoButtonStyle}"/>

            <!-- Clear Button -->
            <Button x:Name="ClearButton"
                            Grid.Column="0" Grid.Row="4"
                            FontSize="16" Padding="7,3" Margin="5"
                            Content="Clear Data"
                            Style="{StaticResource ClearButtonStyle}"
                            Click="ClearButton_Click"/>

            <!-- List Box -->
            <ListBox x:Name="PersonListBox"
                     Grid.Column="1" Grid.Row="0" Grid.RowSpan="5"
                     Margin="5"
                     BorderBrush="DarkSlateGray" BorderThickness="1"
                     ScrollViewer.HorizontalScrollBarVisibility="Disabled"
                     ItemTemplate="{StaticResource PersonListTemplate}">
                <ListBox.ItemsPanel>
                    <ItemsPanelTemplate>
                        <WrapPanel />
                    </ItemsPanelTemplate>
                </ListBox.ItemsPanel>
            </ListBox>

        </Grid>
    </Border>
</Window>
